package svc

import (
	"github.com/zeromicro/go-zero/zrpc"
	"wechat/api/internal/config"
	"wechat/wechatrpc/wechatrpcclient"
)

type ServiceContext struct {
	Config    config.Config
	WechatRpc wechatrpcclient.Wechatrpc
}

func NewServiceContext(c config.Config) *ServiceContext {
	return &ServiceContext{
		Config:    c,
		WechatRpc: wechatrpcclient.NewWechatrpc(zrpc.MustNewClient(c.WechatRpc)),
	}
}
